Total Complexity | 3 |
Total Lines | 44 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | import React from 'react' |
||
5 | |||
6 | class HelpControl extends React.Component { |
||
7 | // Load LibChat script |
||
8 | componentDidMount() { |
||
9 | let e = document.createElement('script') |
||
10 | e.src = |
||
11 | '//v2.libanswers.com/load_chat.php?hash=07713bc057f66ebcdccd4dd1b4a2be3e' |
||
12 | document.body.appendChild(e) |
||
13 | } |
||
14 | |||
15 | render() { |
||
16 | return ( |
||
17 | <div |
||
18 | className={ |
||
19 | this.props.open ? 'header__control--active' : 'header__control' |
||
20 | } |
||
21 | > |
||
22 | <button className="header__control-button" onClick={this.props.handler}> |
||
23 | <div className="header__control-icon"> |
||
24 | <ReactSVG path={askusIcon} /> |
||
25 | </div> |
||
26 | Ask us |
||
27 | </button> |
||
28 | |||
29 | <div className="header__control-popout" style={{ width: '12rem' }}> |
||
30 | <div className="header__popout-setting"> |
||
31 | Text: <a href="tel:5207627271">(520) 762-7271</a> |
||
32 | </div> |
||
33 | <div className="header__popout-setting"> |
||
34 | Phone: <a href="tel:5206216442">(520) 621-6442</a> |
||
35 | </div> |
||
36 | <div className="header__popout-setting"> |
||
37 | Email: <a href="mailto:[email protected]">[email protected]</a> |
||
38 | </div> |
||
39 | <div className="header__popout-setting"> |
||
40 | <div id="libchat_07713bc057f66ebcdccd4dd1b4a2be3e" /> |
||
41 | </div> |
||
42 | <div className="header__popout-setting"> |
||
43 | <a href="http://new.library.arizona.edu/contact"> |
||
44 | More contact information |
||
45 | </a> |
||
46 | </div> |
||
47 | </div> |
||
48 | </div> |
||
49 | ) |
||
54 |